package com.han.entity;

import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;
import java.util.List;


public class PageDTO<T> implements Serializable {
    private static final long serialVersionUID = -1317065534303322382L;
    /**
     * 查询总数
     */
    @ApiModelProperty("查询总数")
    private Long total;

    /**
     * 当前页码
     */
    @ApiModelProperty("当前页码")
    private Integer page;

    /**
     * 每页数量
     */
    @ApiModelProperty("每页数量")
    private Integer limit;

    /**
     * 返回结果集
     */
    @ApiModelProperty("返回结果集")
    private List<T> tableData;

    @Override
    public String toString() {
        return "PageDTO{" +
                "total=" + total +
                ", page=" + page +
                ", limit=" + limit +
                ", tableData=" + tableData +
                '}';
    }

    public Long getTotal() {
        return total;
    }

    public void setTotal(Long total) {
        this.total = total;
    }

    public Integer getPage() {
        return page;
    }

    public void setPage(Integer page) {
        this.page = page;
    }

    public Integer getLimit() {
        return limit;
    }

    public void setLimit(Integer limit) {
        this.limit = limit;
    }

    public List<T> getTableData() {
        return tableData;
    }

    public void setTableData(List<T> tableData) {
        this.tableData = tableData;
    }
}
